<template>
    <div>
        <TypeNav></TypeNav>
        <List></List>
        <Today></Today>
        <Rank></Rank>
        <Like></Like>
        <!-- 楼层 遍历响应回来的数据 并将数据传递给floor -->
        <Floor v-for="floor in floorsList" :key="floor.id" :floor="floor" :id="floor.id"></Floor>
        <Brand></Brand>
        
    </div>
</template>

<script>
// import TypeNav from './TypeNav/index.vue';
import List from './List/index.vue';
import Today from './Today/index.vue';
import Rank from './Rank/index.vue';
import Like from './Like/index.vue';
import Floor from './Floor/index.vue';
import Brand from './Brand/index.vue';
import { mapState } from 'vuex';
export default {
    name: "HomePage",
    components: { List, Today, Rank, Like, Floor, Brand },
    mounted(){
        //获取楼层数据
        this.$store.dispatch('home/getFloorListData')
        // console.log(222,this.floorsList);
    },
    computed:{
        ...mapState('home',['floorsList'])
    }
}
</script>

<style scoped>

</style>